package com.example.firstapp.core;

import java.util.Comparator;

import com.example.firstapp.entity.Restaurant;

public class RestaurantComparator implements Comparator<Restaurant> {

	@Override
	public int compare(Restaurant lhs, Restaurant rhs) {
		double rate1 = lhs.getSystemScore();
		double rate2 = rhs.getSystemScore();
		return Double.compare(rate1, rate2);
	}

}
